<template>
  <el-card>
    <div slot="header">热点效果</div>
    <div class="hotdot-box">
      <div class="dotted"></div>
      <div class="pulse1"></div>
      <div class="pulse2"></div>
      <div class="pulse3"></div>
    </div>
  </el-card>
</template>

<script>
export default {}
</script>

<style lang="less" scoped>
.hotdot-box {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 10px auto;
  border: 1px dotted #cccccc;

  div {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }

  .dotted {
    width: 10px;
    height: 10px;
    background-color: red;
    border-radius: 50%;
  }

  @keyframes pulse {
    0% {
    }
    70% {
      width: 40px;
      height: 40px;
      opacity: 1;
    }
    100% {
      width: 70px;
      height: 70px;
      opacity: 0;
    }
  }

  .pulse2 {
    animation-delay: 0.5s;
  }

  .pulse3 {
    animation-delay: 1s;
  }
}

div[class^='pulse'] {
  width: 10px;
  height: 10px;
  box-shadow: 0 0 12px red;
  border-radius: 50%;
  animation: pulse 1.5s linear 0s infinite;
}
</style>
